const express = require('express')

const router = express.Router()
const type_hanlder = require('../router_hanlder/type')
const expressJoi = require('@escook/express-joi')
const type_schema = require('../schema/type')

//查询
router.get('/',type_hanlder.getType)


//新增
router.post('/add',expressJoi(type_schema.addType),type_hanlder.addType)

//修改
router.post('/edit',expressJoi(type_schema.editType),type_hanlder.editType)

//删除
router.post('/delete',expressJoi(type_schema.deleteType),type_hanlder.deleteType)

module.exports = router